const initialState = {
  needWarning: 0
};

export default {
  name: 'pageClose',
  state: initialState,
  reducers: {
    waringAdd: (state) => {
      return {
        ...state,
        needWarning: state.needWarning + 1,
      };
    },
    waringReduce: (state) => {
      return {
        ...state,
        needWarning: state.needWarning - 1
      };
    },
  },
}
